import Vue from 'vue'
import Router from 'vue-router'
import HelloWorld from '@/components/HelloWorld'
import Index from "../components/Index";
// import ChinaIndex from "../components/views/China/ChinaIndex";
// import ChinaLineChart from "../components/views/China/ChinaLineChart";
// import TraceAbility from "../components/views/China/TraceAbility";
// import HorizontalMenu from "../components/HorizontalMenu";
import MyLayout from '@/components/MyLayout';
// import ChinaEpidemic from "../components/views/China/ChinaEpidemic";
import SuppliesAround from "../components/views/Material/SuppliesAround";
// import MaterialIndex from "../components/views/Material/MaterialIndex";
// import MaterialApplication from "../components/views/Material/MaterialApplication";
// import DietOrder from "../components/views/Material/DietOrder";
// import VariationHistory from "../components/views/VaccineRAD/VariationHistory";
// import PharmaceuticalIP from "../components/views/VaccineRAD/PharmaceuticalIP";
// import MarketAnalysis from "../components/views/Instrument/MarketAnalysis";
const MarketAnalysis = () => import('../components/views/Instrument/MarketAnalysis')
// import SearchByCrawler from "../components/views/Instrument/SearchByCrawler";
const SearchByCrawler = () => import('../components/views/Instrument/SearchByCrawler')
// import Manufacturing from "../components/views/Instrument/Manufacturing";
const Manufacturing = () => import('../components/views/Instrument/Manufacturing')
// import EquipmentIP from "../components/views/Instrument/EquipmentIP";
const EquipmentIP = () => import('../components/views/Instrument/EquipmentIP')
// import D2 from '../components/views/test/d2';
// import MemorialImage from "../components/views/MemorialHall/MemorialImage";
// import EpidemicCulture from "../components/views/MemorialHall/EpidemicCulture";
import mix from "../components/views/Support/mix";
// const mix = () => import('../components/views/Support/mix')
import docFullScreen from "../components/views/Support/DocFullScreen";
import App from "../App";


Vue.use(Router)

export default new Router({
  mode: 'hash',//据说可解决刷新报404
  // mode: 'history',
  base: 'epidemic',
  routes: [
    {
      path: '/',
      name: 'Index',
      component: Index,
      redirect: '/mix',
      children: [{path: '/mix.vue',component: mix}
        // ,
        // {path:'/d2',component: D2}
      ]
    },
    // vue异步组件
    // {
    //   path: '/ChinaEpidemic',
    //   name: 'ChinaEpidemic',
    //   component: resolve => require(['@/components/views/China/ChinaEpidemic'], resolve)
    // },
    // vue异步组件
    // {
    //   path: '/ChinaIndex',
    //   name: 'ChinaIndex',
    //   component: resolve => require(['@/components/views/China/ChinaIndex'], resolve)
    // },
    // {
    //   path: '/China/ChinaLineChart',
    //   name: 'ChinaLineChart',
    //   component: (resolve) => require(['@/components/views/China/ChinaLineChart'], resolve)
    // },
    // {
    //   path: '/China/TraceAbility',
    //   name: 'TraceAbility',
    //   component: (resolve) => require(['@/components/views/China/TraceAbility'], resolve)
    // },
    // {
    //   path: '/HorizontalMenu',
    //   name: 'HorizontalMenu',
    //   component: (resolve) => require(['@/components/HorizontalMenu'], resolve)
    // },
    // {
    //   path: '/MaterialIndex',
    //   name: 'MaterialIndex',
    //   component: (resolve) => require(['@/components/views/Material/MaterialIndex'], resolve)
    // },
    // {
    //   path: '/MaterialApplication',
    //   name: 'MaterialApplication',
    //   component: (resolve) => require(['@/components/views/Material/MaterialApplication'], resolve)
    // },
    // {
    //   path: '/DietOrder',
    //   name: 'DietOrder',
    //   component: (resolve) => require(['@/components/views/Material/DietOrder'], resolve)
    // },
    // {
    //   path: '/VariationHistory',
    //   name: 'VariationHistory',
    //   component: (resolve) => require(['@/components/views/VaccineRAD/VariationHistory'], resolve)
    // },
    // {
    //   path: '/PharmaceuticalIP',
    //   name: 'PharmaceuticalIP',
    //   component: (resolve) => require(['@/components/views/VaccineRAD/PharmaceuticalIP'], resolve),
    // },

    {
      path: '/MarketAnalysis',
      name: 'MarketAnalysis',
      component: (resolve) => require(['@/components/views/Instrument/MarketAnalysis'], resolve),
    },


    // {
    //   path: '/SearchByCrawler',
    //   name: 'SearchByCrawler',
    //   component: (resolve) => require(['@/components/views/Instrument/SearchByCrawler'], resolve),
    // },

    {
      path: '/Manufacturing',
      name: 'Manufacturing',
      component: (resolve) => require(['@/components/views/Instrument/Manufacturing'], resolve),
    },
    {
      path: '/EquipmentIP',
      name: 'EquipmentIP',
      component: (resolve) => require(['@/components/views/Instrument/EquipmentIP'], resolve),
    },
    // {
    //   path: '/MemorialImage',
    //   name: 'MemorialImage',
    //   component: (resolve) => require(['@/components/views/MemorialHall/MemorialImage'], resolve)
    // },
    // {
    //   path: '/EpidemicCulture',
    //   name: 'EpidemicCulture',
    //   component: (resolve) => require(['@/components/views/MemorialHall/EpidemicCulture'], resolve)
    // },
    {
      path: '/mix',
      name: 'mix',
      component: (resolve) => require(['@/components/views/Support/mix'], resolve),
      children:[
        {
          path:"/docRead",
          name:'DocRead',
          component: ()=>
            import("@/components/views/Support/docRead.vue"),
          hidden: true
        },
        {
          path:"/docFullScreen",
          name:'DocFullScreen',
          component: ()=>
            import("@/components/views/Support/DocFullScreen.vue"),
          hidden: true
        },
        {
          path:"/videoPlay",
          name:'videoPlay',
          component: ()=>
            import("@/components/views/Support/videoPlay.vue"),
          hidden: true
        },
        {
          path:"/DocumentUpload",
          name:'文档分享',
          component: ()=>
            import("@/components/views/Support/DocumentUpload.vue"),
          hidden: true
        },
        {
          path:"/VideoUpload",
          name:'视频分享',
          component: ()=>
            import("@/components/views/Support/VideoUpload.vue"),
          hidden: true
        },
      ]
    }
  ]
})
